package com.fanfan.SmartPensionSystembackend.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * @Description user
 * @Author Guangdi Chen
 * @Date 2025-03-05
 */

@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName(value = "sysuser", autoResultMap = true) // 明确指定表名
public class User {
    @TableId(value = "userId", type = IdType.INPUT)
    private String userId;
    @TableField("username")
    private String username;
    @TableField("password")
    private String password;
    @TableField("realName")
    private String realName;
    @TableField("phone")
    private String phone;
    public enum type {
         admin, staff; // 添加 "staff" 到枚举值列表中
    }
    @TableField("userType")
    private type userType;
    private String code;
}